<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
<title>访问统计</title>
<link rel="stylesheet" type="text/css" href="$request.getContextPath()/resources/bootstrap/css/bootstrap.min.css" rel="stylesheet">
<script type="text/javascript" src="$request.getContextPath()/resources/jquery/jquery-3.1.0.min.js"></script>
<script type="text/javascript" src="$request.getContextPath()/resources/bootstrap/js/bootstrap.min.js"></script>

<script src="$request.getContextPath()/resources/highcharts/highcharts.js"></script>
<script src="$request.getContextPath()/resources/highcharts/modules/exporting.js"></script>

<style type="text/css">
body,.container-fluid,.container-fluid #accessContainer{
   width: 100%;
   height: 100%;
   position: absolute;
   padding:0px;
   margin:0px;
}
.highcharts-credits{
   visibility: hidden;
}
</style>
<script type="text/javascript">
$(function () {
    $.getJSON('https://www.highcharts.com/samples/data/jsonp.php?filename=usdeur.json&callback=?', function (data) {
    	console.log(data);
        $('#accessContainer').highcharts({
            chart: {
                zoomType: 'x'
            },
            title: {
                text: '用户访问次数统计图'
            },
            xAxis: {
                type: 'datetime'
            },
            yAxis: {
                title: {
                    text: '访问次数(W)'
                }
            },
            legend: {
                enabled: false
            },
            plotOptions: {
                area: {
                    fillColor: {
                        linearGradient: {
                            x1: 0,
                            y1: 0,
                            x2: 0,
                            y2: 1
                        },
                        stops: [
                            [0, Highcharts.getOptions().colors[0]],
                            [1, Highcharts.Color(Highcharts.getOptions().colors[0]).setOpacity(0).get('rgba')]
                        ]
                    },
                    marker: {
                        radius: 2
                    },
                    lineWidth: 1,
                    states: {
                        hover: {
                            lineWidth: 1
                        }
                    },
                    threshold: null
                }
            },
            series: [{
                type: 'area',
                name: 'USD to EUR',
                data: data
            }]
        });
    });
});
</script>
</head>
<body>
<div class="container-fluid">
	<div id="accessContainer"></div>
</div>
</body>
</html>